class ImEntity {
	ImMessage message;
	ImTimconversation timConversation;
  String sender;
	ImEntity({this.message, this.timConversation});

	ImEntity.fromJson(Map<String, dynamic> json) {
    sender = json['sender'] != null ? json['sender'] : "";
		message = json['message'] != null ? new ImMessage.fromJson(json['message']) : null;
		timConversation = json['timConversation'] != null ? new ImTimconversation.fromJson(json['timConversation']) : null;
	}

	Map<String, dynamic> toJson() {
		final Map<String, dynamic> data = new Map<String, dynamic>();
		if (this.message != null) {
      data['message'] = this.message.toJson();
    }
		if (this.timConversation != null) {
      data['timConversation'] = this.timConversation.toJson();
    }
    data["sender"] = this.sender;
		return data;
	}
}

class ImMessage {
	String text;
	dynamic type;

	ImMessage({this.text, this.type});

	ImMessage.fromJson(Map<String, dynamic> json) {
		text = json['text'];
		type = json['type'];
	}

	Map<String, dynamic> toJson() {
		final Map<String, dynamic> data = new Map<String, dynamic>();
		data['text'] = this.text;
		data['type'] = this.type;
		return data;
	}
}

class ImTimconversation {
	String peer;
	dynamic type;

	ImTimconversation({this.peer, this.type});

	ImTimconversation.fromJson(Map<String, dynamic> json) {
		peer = json['peer'];
		type = json['type'];
	}

	Map<String, dynamic> toJson() {
		final Map<String, dynamic> data = new Map<String, dynamic>();
		data['peer'] = this.peer;
		data['type'] = this.type;
		return data;
	}
}
